package org.jks.controller;

import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import org.jks.config.Config;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

@Controller
@RequestMapping("/manage")
public class ManageController {

	@RequestMapping("/")
	public ModelAndView forward(HttpServletRequest request,
			HttpServletResponse response, HttpSession session,
			Map<String, Object> model) {
		Config.init(request, response, session, model, 0);
		return new ModelAndView("manage/index", model);
	}

	@RequestMapping("/index")
	public ModelAndView index(HttpServletRequest request,
			HttpServletResponse response, HttpSession session,
			Map<String, Object> model) {
		Config.init(request, response, session, model, 0);
		return new ModelAndView("manage/index", model);
	}

}
